import { ReactComponent as FullLogo } from '@/assets/svg/assets-logo-full.svg';
import { ReactComponent as MiniLogo } from '@/assets/svg/assets-t-logo.svg';
import React from 'react';
import styles from '../../AsideHeader.module.less';
import { useNavigate } from 'react-router-dom';
interface IProps {
    collapsed?: boolean
}

const Logo = React.memo<IProps>((props) => {

    const nav = useNavigate();

    function handleClick() {
        nav('/');
    }

    return <div className={styles.logoFull}>
        <div className={styles.menuLogo} onClick={handleClick}>
            {props.collapsed ? <MiniLogo /> : <FullLogo />}
        </div>
    </div>
});

export default Logo;